
<template>
	<el-dialog title=""  visible :show-close="false" :append-to-body="true" class="wrap" >
		<i class="el-icon-close close" @click="cancel" style="color: white;z-index:10;"></i>
	    <div class="bt">上课时间</div>
		<el-form label-width="100px" class="form">
 			<el-tabs v-model="activeName"  style="text-align: center;">
			
		<!--	<el-tab-pane label="考试成绩" name="third">-->
			      <el-table :data="dyjkdataList" stripe style="width: 100%">
					<el-table-column prop="jsmc" label="教室名称"></el-table-column>
					<el-table-column prop="lsmc" label="老师名称"></el-table-column>
					<el-table-column prop="sjd" label="上课时间"></el-table-column>
				  </el-table>
			    <!--</el-tab-pane>-->
        </el-tabs>
		</el-form>
		<el-button type="primary" class="submit" @click="cancel">确定</el-button>

	</el-dialog>
</template>

<script type="text/javascript">
	import qs from 'qs'
	export default {
		props: ['params'],
		data() {
			return {
				 activeName: 'third',
				form: {
					id:'',
					zt:1,
				},
				dyjkdataList:[],
			}
		},
		created() {
//			alert(this.params)
//         this.form.id=this.params.row.id;
//         this.form.wpid=this.params.row.wpid;
           this.dyjk();
//		 this.form.zt = this.params.row.zt;

//			this.loadinfo();
		},
		methods: {
			dyjk() {
				var logininfo = JSON.parse(localStorage.logininfo);
              this.searchLoading = true;
             var params2 = qs.stringify({
             	     bjid:this.params,
                     yhid:this.form.id,
                      xxid:logininfo.xxid
               })
             //执行
                 this.axios.post(this.$store.state.api + 'xxjs/firstkb',  params2 )
                 .then(res => {
					console.log(res)
					let data = res.data.data;
						let list = data.list;
						this.dyjkdataList = list;
					this.searchLoading = false;
                 }).catch(res => {
					 console.log(res)
                  this.searchLoading = false;
				})	
			},
			cancel() {
				this.$emit('close', { type: 'dyjk', cancel: true })
			}
		}
	}
</script>

<style lang="less" scoped>
	.wrap {
		text-align: center;
	}
	.bt{
		position: absolute;
		width: 100%;
		height: 50px;
		margin: 0 auto;
		top: 0;
		left: 0;
		background: #50BFFF;
		color:white;
		text-align:left;
		line-height: 50px;
		font-size: 17px;
		padding-left: 15px;
	}
	.form {
		text-align: center;
		font-size:20px ;
		margin-bottom: 20px;
		margin-top: 10px;
		color:red;
	}
	 .input {
            width: 300px;
            display: inline-block;
        }

	.select-block {
		display: block;
	}

	.submit {
		width: 120px;
	}
</style>
